$table-border-color: #ebeef5;
$table-border-width: 1px;
$table-header-background-color: #f5f7fa;

$table-row-active-background-color:#e7f0fe;

.table-container {
    width: inherit;
    /* 设置表格容器的宽度 */
    overflow-x: auto;
    /* 横向滚动条 */
    overflow-y: hidden;
    /* 隐藏纵向滚动条 */

    table {
        position: relative;
        margin: auto;
        background: #fff;
        border-collapse: collapse;
        border-spacing: 0;
        table-layout: fixed;
        font-size: 12px;
        box-sizing: content-box;
        border: 0;

        thead {
            background-color: $table-header-background-color;

            th {
                font-size: 12px;
            }
        }

        th,
        td {
            position: relative;
            //   vertical-align: top;
            height: 38px;
            // padding-left: 10px;
            font-size: 13px;
            // border: 1px solid #000;
            box-sizing: content-box;
            background-image: linear-gradient($table-border-color, $table-border-color), linear-gradient($table-border-color, $table-border-color);
            background-repeat: no-repeat;
            background-size: 1px 100%, 100% 1px;
            background-position: 100% 0, 100% 100%;

            .square {
                width: 12px;
                height: 12px;
                // border: 1px solid #000;
                font-size: 12px;
                display: inline-block;
                margin-right: 5px;
            }

            &.tdTitle {
                font-size: 13px;
            }

            &.sticky_left,
            &.sticky_right {
                // background: #fff;
            }
        }

        td {
            padding: 0 10px;
        }

        tr {
            box-sizing: content-box;

            &.row-active--high {
                td {
                    background-color: $table-row-active-background-color;
                }
            }
        }

        .emptyTr {
            border-top: 1px solid #000;
        }

        .tbody {
            vertical-align: top;
            border-bottom-style: none;

            // border-block-color: #fff;
            td {
                font-size: 12px;
                font-weight: bold;
            }
        }
    }


    .sticky_left {
        position: sticky;
        top: auto;
        z-index: 8;
        left: 0;
        box-sizing: content-box;
        background-image: linear-gradient($table-border-color, $table-border-color), linear-gradient($table-border-color, $table-border-color);
        background-repeat: no-repeat;
        background-size: 1px 100%, 100% 1px;
        background-position: 100% 0, 100% 100%;

        // &.after {
        //     box-shadow: 10px 10px 5px 0 black;
        // }

        // &::before {
        //     content: '';
        //     width: 100%;
        //     height: 1px;
        //     background: #dedede;
        //     position: absolute;
        //     bottom: -1px;
        // }
    }

    .left {
        .shadow_left::after {
            content: '';
            width: 10px;
            height: 100%;
            background-image: linear-gradient(to left, rgba(0, 0, 0, 0), rgba(0, 0, 0, 0.1));
            position: absolute;
            top: 0;
            right: -10px;
            z-index: 9;
            transition: all 0.2s;
        }

        th {
            background-color: #f5f7fa;
        }

        td {
            background-color: #fff;
        }
    }

    .table--border-line {
        position: absolute;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        z-index: 10;
        pointer-events: none;
        border: $table-border-width solid $table-border-color;
    }
}